//
//  NGLocation.h
//  SudzCExamples
//
//  Created by Mehmet Sinan Şahin on 12/28/11.
//  Copyright 2011 netgis. All rights reserved.
//

#import <Foundation/Foundation.h>
@class CLLocation;
@class AStatusSpeedStrategy;
@class RotatingNGLocation;

@interface NGLocation : NSObject {

    int _id; //for database, afterwards deletion by id
	NSString *deviceCode;
	double lat;
	double lon;
	NSDate *tarihSaat;
	NSString *speed;
	int status; 
    NSDate *date;
    BOOL sent;
    AStatusSpeedStrategy *strategy;
	
}

@property(retain) NSString *deviceCode;
@property(retain) NSDate *tarihSaat; //timestamp, location retrieve time
@property(retain) NSString *speed;
@property(retain) NSDate *date; //creation time of object
@property double lat;
@property double lon;
@property int status;
@property BOOL sent;
@property int _id;
@property (retain) AStatusSpeedStrategy *strategy;

+(NGLocation *) initWithCLLocation:(CLLocation *)location;
-(BOOL)isEqualTo:(NGLocation *)loc;
-(void)calculateSpeedAndStatus: (RotatingNGLocation *) lastNLocations;

@end
